<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<jsp:include page="../head.jsp">
<jsp:param value="客户信息" name="title"/>
</jsp:include>
</head>
<body>
	<div class="container">
		<div class="row">
			<div id="content" class="col-lg-12">
				<div class = "dao">		
					<a class="section" href = "manager">客户跟进</a>
					<i class="right chevron icon divider"></i>
					<a class="section" href = "cust/form">客户管理</a>
					<i class="right chevron icon divider"></i>
					<span class="active section">修改信息</span>							
				</div>
				<div class = "content">
					<form  method="post" class="ui form create-form">
					<c:forEach items="${ sessionScope.custList }" var="custList">
						<c:if test="${ custList.cust_id eq id }">
							<div class="two fields">
								<div class="field">
									<input type="hidden" name="id" value="${custList.cust_id }">
									<label>姓名</label> 
									<input name="name" type="text" value="${custList.cust_name }"  >
								</div>
								<div class="field">
									<label>性别</label>
									<div class="ui selection dropdown">
										<input name="gender" type="hidden" value="${custList.cust_gender }">
										<div class="default text">请选择性别</div>
										<i class="dropdown icon"></i>
										<div class="menu">
											<div class="item" data-value="男">男</div>
											<div class="item" data-value="女">女</div>
										</div>
									</div>
								</div>
							</div>
				<div class="field">
					<label>家庭住址</label>
					<input name="address" type="text" value="${custList.cust_address }"  >
				</div>
				<div class="two fields">
					<div class="field">
						<label>电话</label> 
						<input name="tel" type="text" value="${custList.cust_telphone }"  >
					</div>
					<div class="field">
						<label>QQ</label>
						<input name="qq" type="text" value="${custList.cust_qq }"  >
					</div>
				</div>
				<div class="field">
					<label>学历</label>
					<div class="ui selection dropdown">
			          <input type="hidden" name="degreeId" value="${custList.cust_degree_id }">
			          <i class="dropdown icon"></i>
			          <div class="default text">请选择学历</div>
			          <div class="menu">
			          	 <c:forEach items="${ listDegree }" var="listDegree">
			              <div class="item" data-value="${listDegree.degree_id }">
				            ${listDegree.degree_name }
			              </div>
			              </c:forEach>
			          </div>
			       	</div>
				</div>
				<div class="two fields">
					<div class="field">
						<label>父(母)亲姓名</label>
						<input name="pname" type="text" value="${custList.cust_parentName }"  >
					</div>
					<div class="field">
						<label>父(母)亲电话</label> 
						<input name="ptel" type="text" value="${custList.cust_parentTel }"  >
					</div>
				</div>
				<div class="field">
					<label>信息来源</label>
					<input name="source" type="text" value="${custList.cust_source }"  >
				</div>
			  <button class="ui button" type="submit">保存</button>
			  <button class="ui button" type="button" onclick="window.location.href='cust/form'">取消</button>
			  <span style="color:red">${ error }</span>
			</c:if>
		</c:forEach>
		</form>
	</div>
</div>
</body>
</html>